Micron Document




Boa (JavaScript engine)
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
top
Boa is an open-source JavaScript engine written in Rust.cite-ref-boa-about-2-1[2] Boa was introduced at JSConf EU 2019 by Jason Williams.cite-ref-boa-talk-3-0[3]cite-ref-jsonconf-eu-4-0[4]

Williams created Boa in 2017 after working on Servo and being inspired by the "written from scratch" CSS engine.cite-ref-5[5]cite-ref-jsonconf-eu-4-1[4] He was eager to work on a JavaScript engine using Rust to learn more about how JavaScript implementations work, since then the project has had over 100 contributors.cite-ref-boa-talk-3-1[3]cite-ref-6[6] Overtime the engine gained more prominent features such as bytecode compilation,cite-ref-7[7] better conformance to the specification and ergonomic API design.cite-ref-latest-release-1-1[1]

Contents

Design

──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────

Design

Boa is an open-source implementation of a JavaScript execution engine. The project is developed as a Rust library for embedding the JavaScript engine in Rust applications. Additionally, the authors of Boa provide a command-line interface (CLI) for users to interact with Boa as standalone JavaScript interpreter accessible from a command line.cite-ref-boaspect-8-0[8]

Boa follows the common interpreter design which approximately consists of a lexer, parser, compiler and bytecode interpretercite-ref-boaspect-8-1[8]

Standards

Boa implements the ECMA-262 specification (ECMAScript). As of 6 September 2024 Boa has 88% conformance to Test262cite-ref-9[9]

See also

JerryScript, an ultra-lightweight JavaScript engine
SpiderMonkey, a JavaScript engine used in Firefox

References

cite-note-latest-release-11. "Boa release v0.19". boajs.dev. 5 December 2024.
cite-note-boa-about-22. "About Boa | Boa JS". boajs.dev. Boa Developers. Retrieved 15 October 2024.
cite-note-boa-talk-33. citerefwilliams2019Williams, Jason (20 June 2019). "Let's build a JavaScript Engine in Rust by Jason Williams - JSConf EU 2019". YouTube. JS Conf EU. Retrieved 15 October 2024.
cite-note-jsonconf-eu-44. citerefjason-williamsJason Williams. "Let's build a JavaScript Engine". 2019.jsconf.eu. JS Conf EU. Archived from the original on 25 February 2024. Retrieved 25 February 2024.
cite-note-55. "Hacking & Contributing to Servo On Windows – Mozilla Hacks - the Web developer blog". Mozilla Hacks – the Web developer blog.
cite-note-66. "Contributors to boa-dev/boa". GitHub.
cite-note-77. "Boa release v0.14". boajs.dev. 15 March 2022.
cite-note-boaspect-88. citerefmunstersMunsters, Aäron. "BoaSpect" (PDF). Vrije Universiteit Brussel. Retrieved 15 October 2024.
cite-note-99. "test262.fyi". test262.fyi. 6 September 2024. Archived from the original on 6 September 2024. Retrieved 6 September 2024.